<%- include('layouts/head.ejs', { pageConf })%>

<%- include('common/nav.ejs')%>

<h1>管理题目类型</h1>

<table class="layui-table">
  <thead>
    <tr>
      <% pageConf.table_head.forEach((item, index) => { %>
      <th class="problem-th"><%= item %></th>
      <% }) %>
    </tr>
  </thead>
  <tbody>

    <% problemList.forEach((item, index) => { %>
    <tr>
      <td class="problem-td"><%= item.id %></td>
      <td class="problem-td"><%= item.type_title %></td>
      <td class="problem-td"><%= item.isBasic%></td>
      <td><a class="edit-btn" href="/admin/edit-problem-type/<%= item.id%>">编辑</a></td>
      <td><a class="delete" href="/admin/delete-problem-type/<%= item.id%>">删除</a></td>
    </tr>
    <% }) %>
  </tbody>
</table>

<%- include('layouts/foot.ejs', { pageConf })%>